package com.jsbs.iam.common.core.enums;

import lombok.Getter;

/**
 * @ClassName ResConst
 * @Author chenzhixiang
 * @Date 2022/6/15 17:14
 * @Version v1.0
 **/
public enum ResConst {
    /**
     * 成功
     */
    OK(0,"成功"),
    FAIL(9,"失败"),
    UNAUTHORIZED_ERROR(401, "未授权"),
    FORBIDDEN_ERROR(403, "拒绝访问"),
    NOT_FOUND_ERROR(404, "404 not found"),
    METHOD_NOT_ALLOWED(405, "不允许此方法"),
    SYSTEM_ERROR(500, "服务繁忙，请稍后再试"),
    ;

    @Getter
    private int code;
    @Getter
    private String message;


    ResConst(int code, String message) {
        this.code = code;
        this.message = message;
    }
}
